<template>
    详情页
  <div>
    <ul>
      <li
        v-for="item in obj"
        :key="item.id"
        @click="$router.push('/xq/') + item.id"
      >
        <img :src="item.image" alt="" />
        <p>{{ item.title }}</p>
        <p>{{ item.price }}</p>
      </li>
    </ul>
  </div>
</template>

<script request>
// import request from "@/uitle/request";
// import { useRoute, useRouter } from "vue-router";
// const route = useRoute();
// const router = useRouter();
// const obj = ref([]);
//   //   console.log(`the component is now mounted.`)
//   request.get("/detail", {
//     params:id,{route.id}
//   }).then((res) => {
//     if (res.data.code == 200) {
//       console.log(res);
//       obj.value = res.data.data;
//     }
//   });
</script>

<style lang="scss" scoped>
</style>